package org.lq.his.dao;

import java.util.List;

import org.apache.ibatis.annotations.Param;
import org.lq.his.pojo.Permission;
import org.omg.CosNaming.NamingContextExtPackage.StringNameHelper;

public interface PermissionDao extends CommonDao<Permission, Integer>{
	
	//删除权限State
	public void deletePermissionsById(Integer id);
	// 根据角色编号查询拥有的权限编号
	public List<Integer> getPermissionIdsByRoleId(Integer roleId);
	//删除权限
	public void deletePermissionsByRoleId(Integer roleId);
	//批量添加权限
	public void addRolePermissions(@Param("roleId")Integer roleId,@Param("perIds") List<Integer> perIds);
	
	//查询用户拥有的所有的功能编号
	public List<String> getPermissionCodeByUserId(Integer userid);
	
	public List<Permission> getPermissionId(Integer id);
}
